package org.classg.edu.client;

import org.classg.edu.client.impl.VodClientImpl;
import org.classg.utils.R;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

@Component
@FeignClient(value = "service-vod", fallback = VodClientImpl.class)
public interface VodClient {

    // 根据视频id删除阿里云视频
    @DeleteMapping("/vodservice/video/deleteVideoByVideoId/{videoId}")
    R deleteVideoByVideoId(@PathVariable("videoId") String videoId);

    // 根据多个视频id删除阿里云多个视频
    @DeleteMapping("/vodservice/video/deleteVideoByVideoIds/{videoIds}")
    R deleteVideoByVideoIds(@RequestParam("videoIds") List<String> videoIds);

}
